package S06;
public class Rectangle extends Shape { //矩形类
	private double width,height;
	public Rectangle(double  width,double height) { //构造方法
		this.width=width;
		this.height=height;
	}
	@Override
	public double getArea() { //重写父类的方法
		return width*height;
	}
	@Override
	public String getName() { //重写父类的方法
		return "矩形";
	}
}
